/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * Payroll.java
 *
 * Created on Dec 3, 2012, 4:02:04 PM
 */
package gui;

import java.awt.Component;
import java.awt.event.ActionEvent;
import java.sql.Date;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Collection;
import java.util.Iterator;
import java.util.ListIterator;
import java.util.Vector;

import javax.swing.ComboBoxModel;
import javax.swing.DefaultListModel;
import javax.swing.JButton;
import javax.swing.JComponent;
import javax.swing.JFrame;
import javax.swing.JLabel;
import javax.swing.JList;
import javax.swing.JOptionPane;
import javax.swing.JPanel;
import javax.swing.JSpinner;
import javax.swing.JTextField;
import javax.swing.SpinnerDateModel;
import javax.swing.SpinnerModel;

import org.joda.time.DateTime;
import org.joda.time.format.DateTimeFormat;
import org.joda.time.format.DateTimeFormatter;

import com.toedter.calendar.JDateChooser;

import pms.DatePicker;
import pms.Employee;
import pms.Log;
import pms.Manager;
import pms.PayrollAdmin;

/**
 * 
 * @author kiserj66
 */
public class Payroll extends javax.swing.JFrame {

	private ArrayList<Employee> e;
	private Vector<String> emp;
	private Vector<Integer> eIds;
	private Vector<Integer> reportIds = new Vector<Integer>();

	/** Creates new form Payroll */
	public Payroll(Employee e) {

		eIds = new Vector<Integer>();

		try {
			if (e instanceof PayrollAdmin) {
				P = new PayrollAdmin(e.getEmployeeID());
			} else {

				m = new Manager(e.getEmployeeID());
				P = new PayrollAdmin(e.getEmployeeID());
			}

			emp = (Vector<String>) P.getList(eIds);

		} catch (Exception e1) {
			// TODO Auto-generated catch block
			e1.printStackTrace();
		}

		initComponents();

		this.em = e;
	}

	/**
	 * This method is called from within the constructor to initialize the form.
	 * WARNING: Do NOT modify this code. The content of this method is always
	 * regenerated by the Form Editor.
	 */
	@SuppressWarnings("unchecked")
	// <editor-fold defaultstate="collapsed"
	// desc="Generated Code">//GEN-BEGIN:initComponents
	private void initComponents() {

		jComboBoxEmployeeInput = new javax.swing.JComboBox(emp);
		jScrollPane1 = new javax.swing.JScrollPane();
		jListEmployees = new javax.swing.JList();
		jButtonAddToList = new javax.swing.JButton();
		jScrollPane2 = new javax.swing.JScrollPane();
		jTextArea1 = new javax.swing.JTextArea();
		jButtonRemoveFromList = new javax.swing.JButton();
		jButtonViewHours = new javax.swing.JButton();
		jButtonUpdateHours = new javax.swing.JButton();
		jButtonChangePay = new javax.swing.JButton();
		jButtonTerminateEmployee = new javax.swing.JButton();
		jButtonGenerateReport = new javax.swing.JButton();
		jButtonCreateJobProfile = new javax.swing.JButton();
		jButtonChangeJobProfile = new javax.swing.JButton();
		jTextArea1.setWrapStyleWord(true);

		setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
		setResizable(false);

		jComboBoxEmployeeInput
				.addActionListener(new java.awt.event.ActionListener() {
					public void actionPerformed(java.awt.event.ActionEvent evt) {
						jTextFieldEmployeeInputActionPerformed(evt);
					}
				});

		DefaultListModel listModel = new DefaultListModel();
		JList jListEmployees = new JList(listModel);

		jScrollPane1.setViewportView(jListEmployees);

		jButtonAddToList.setText("Add To List");
		jButtonAddToList.addActionListener(new java.awt.event.ActionListener() {
			public void actionPerformed(java.awt.event.ActionEvent evt) {
				jButtonAddToListActionPerformed(evt);
			}
		});

		jTextArea1.setColumns(20);
		jTextArea1.setRows(5);
		jScrollPane2.setViewportView(jTextArea1);

		jButtonRemoveFromList.setText("Remove From List");
		jButtonRemoveFromList
				.addActionListener(new java.awt.event.ActionListener() {
					public void actionPerformed(java.awt.event.ActionEvent evt) {
						jButtonRemoveFromListActionPerformed(evt);
					}
				});

		jButtonViewHours.setText("View Hours");
		jButtonViewHours.addActionListener(new java.awt.event.ActionListener() {
			public void actionPerformed(java.awt.event.ActionEvent evt) {
				jButtonViewHoursActionPerformed(evt);
			}
		});

		jButtonUpdateHours.setText("Update Hours");
		jButtonUpdateHours
				.addActionListener(new java.awt.event.ActionListener() {
					public void actionPerformed(java.awt.event.ActionEvent evt) {
						jButtonUpdateHoursActionPerformed(evt);
					}
				});

		jButtonChangePay.setText("Change/Edit Pay");
		jButtonChangePay.addActionListener(new java.awt.event.ActionListener() {
			public void actionPerformed(java.awt.event.ActionEvent evt) {
				jButtonChangePayActionPerformed(evt);
			}
		});

		jButtonTerminateEmployee.setText("Terminate Employee");
		jButtonTerminateEmployee
				.addActionListener(new java.awt.event.ActionListener() {
					public void actionPerformed(java.awt.event.ActionEvent evt) {
						jButtonTerminateEmployeeActionPerformed(evt);
					}
				});

		jButtonGenerateReport.setText("Generate Report");
		jButtonGenerateReport
				.addActionListener(new java.awt.event.ActionListener() {
					public void actionPerformed(java.awt.event.ActionEvent evt) {
						try {
							jButtonGenerateReportActionPerformed(evt);
						} catch (Exception e) {
							// TODO Auto-generated catch block
							e.printStackTrace();
						}
					}
				});

		jButtonCreateJobProfile.setText("Create Job Profile");
		jButtonCreateJobProfile
				.addActionListener(new java.awt.event.ActionListener() {
					public void actionPerformed(java.awt.event.ActionEvent evt) {
						jButtonCreateJobProfileActionPerformed(evt);
					}
				});

		jButtonChangeJobProfile.setText("Change Job Profile");
		jButtonChangeJobProfile
				.addActionListener(new java.awt.event.ActionListener() {
					public void actionPerformed(java.awt.event.ActionEvent evt) {
						jButtonChangeJobProfileActionPerformed(evt);
					}
				});

		javax.swing.GroupLayout layout = new javax.swing.GroupLayout(
				getContentPane());
		getContentPane().setLayout(layout);
		layout.setHorizontalGroup(layout
				.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
				.addGroup(
						layout.createSequentialGroup()
								.addGap(30, 30, 30)
								.addGroup(
										layout.createParallelGroup(
												javax.swing.GroupLayout.Alignment.TRAILING,
												false)
												.addComponent(
														jScrollPane1,
														javax.swing.GroupLayout.Alignment.LEADING)
												.addComponent(
														jComboBoxEmployeeInput,
														javax.swing.GroupLayout.Alignment.LEADING,
														0, 211, Short.MAX_VALUE))
								.addPreferredGap(
										javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
								.addGroup(
										layout.createParallelGroup(
												javax.swing.GroupLayout.Alignment.LEADING,
												false)
												.addComponent(
														jButtonChangeJobProfile,
														javax.swing.GroupLayout.DEFAULT_SIZE,
														javax.swing.GroupLayout.DEFAULT_SIZE,
														Short.MAX_VALUE)
												.addComponent(
														jButtonCreateJobProfile,
														javax.swing.GroupLayout.DEFAULT_SIZE,
														javax.swing.GroupLayout.DEFAULT_SIZE,
														Short.MAX_VALUE)
												.addComponent(
														jButtonGenerateReport,
														javax.swing.GroupLayout.DEFAULT_SIZE,
														javax.swing.GroupLayout.DEFAULT_SIZE,
														Short.MAX_VALUE)
												.addComponent(
														jButtonTerminateEmployee,
														javax.swing.GroupLayout.DEFAULT_SIZE,
														javax.swing.GroupLayout.DEFAULT_SIZE,
														Short.MAX_VALUE)
												.addComponent(
														jButtonUpdateHours,
														javax.swing.GroupLayout.DEFAULT_SIZE,
														javax.swing.GroupLayout.DEFAULT_SIZE,
														Short.MAX_VALUE)
												.addComponent(
														jButtonViewHours,
														javax.swing.GroupLayout.DEFAULT_SIZE,
														javax.swing.GroupLayout.DEFAULT_SIZE,
														Short.MAX_VALUE)
												.addComponent(
														jButtonRemoveFromList,
														javax.swing.GroupLayout.DEFAULT_SIZE,
														javax.swing.GroupLayout.DEFAULT_SIZE,
														Short.MAX_VALUE)
												.addComponent(
														jButtonAddToList,
														javax.swing.GroupLayout.DEFAULT_SIZE,
														221, Short.MAX_VALUE)
												.addComponent(
														jButtonChangePay,
														javax.swing.GroupLayout.Alignment.TRAILING,
														javax.swing.GroupLayout.DEFAULT_SIZE,
														javax.swing.GroupLayout.DEFAULT_SIZE,
														Short.MAX_VALUE))
								.addPreferredGap(
										javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
								.addComponent(jScrollPane2,
										javax.swing.GroupLayout.DEFAULT_SIZE,
										241, Short.MAX_VALUE).addContainerGap()));
		layout.setVerticalGroup(layout
				.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
				.addGroup(
						layout.createSequentialGroup()
								.addContainerGap()
								.addGroup(
										layout.createParallelGroup(
												javax.swing.GroupLayout.Alignment.TRAILING,
												false)
												.addComponent(
														jScrollPane2,
														javax.swing.GroupLayout.Alignment.LEADING)
												.addGroup(
														javax.swing.GroupLayout.Alignment.LEADING,
														layout.createSequentialGroup()
																.addGroup(
																		layout.createParallelGroup(
																				javax.swing.GroupLayout.Alignment.BASELINE)
																				.addComponent(
																						jComboBoxEmployeeInput,
																						javax.swing.GroupLayout.PREFERRED_SIZE,
																						javax.swing.GroupLayout.DEFAULT_SIZE,
																						javax.swing.GroupLayout.PREFERRED_SIZE)
																				.addComponent(
																						jButtonAddToList))
																.addPreferredGap(
																		javax.swing.LayoutStyle.ComponentPlacement.RELATED)
																.addGroup(
																		layout.createParallelGroup(
																				javax.swing.GroupLayout.Alignment.LEADING)
																				.addGroup(
																						layout.createSequentialGroup()
																								.addComponent(
																										jButtonRemoveFromList)
																								.addPreferredGap(
																										javax.swing.LayoutStyle.ComponentPlacement.RELATED)
																								.addComponent(
																										jButtonViewHours)
																								.addPreferredGap(
																										javax.swing.LayoutStyle.ComponentPlacement.RELATED)
																								.addComponent(
																										jButtonUpdateHours)
																								.addPreferredGap(
																										javax.swing.LayoutStyle.ComponentPlacement.RELATED)
																								.addComponent(
																										jButtonChangePay)
																								.addPreferredGap(
																										javax.swing.LayoutStyle.ComponentPlacement.RELATED)
																								.addComponent(
																										jButtonTerminateEmployee)
																								.addPreferredGap(
																										javax.swing.LayoutStyle.ComponentPlacement.RELATED)
																								.addComponent(
																										jButtonGenerateReport)
																								.addPreferredGap(
																										javax.swing.LayoutStyle.ComponentPlacement.RELATED)
																								.addComponent(
																										jButtonCreateJobProfile)
																								.addPreferredGap(
																										javax.swing.LayoutStyle.ComponentPlacement.RELATED)
																								.addComponent(
																										jButtonChangeJobProfile))
																				.addComponent(
																						jScrollPane1,
																						javax.swing.GroupLayout.PREFERRED_SIZE,
																						236,
																						javax.swing.GroupLayout.PREFERRED_SIZE))
																.addPreferredGap(
																		javax.swing.LayoutStyle.ComponentPlacement.RELATED)))
								.addContainerGap(15, Short.MAX_VALUE)));

		pack();
	}

	public boolean emptyList() {
		if (!(jListEmployees.getModel().getSize() == 0))
			return true;
		else {
			JOptionPane
					.showMessageDialog(
							getComponent(0),
							"The list is currently empty... Please add employees to the list and try again.");
			return false;
		}
	}

	private void jButtonAddToListActionPerformed(java.awt.event.ActionEvent evt) {// GEN-FIRST:event_jButtonAddToListActionPerformed
		// TODO add your handling code here:
		int k = jComboBoxEmployeeInput.getSelectedIndex();
		int index = jComboBoxEmployeeInput.getSelectedIndex();
		reportIds.add(eIds.elementAt(index));
		String info = emp.elementAt(index);
		listModel.addElement(info);
		jListEmployees = new JList<String>(listModel);
		jScrollPane1.setViewportView(jListEmployees);
	}// GEN-LAST:event_jButtonAddToListActionPerformed

	private void jButtonRemoveFromListActionPerformed(
			java.awt.event.ActionEvent evt) {// GEN-FIRST:event_jButtonRemoveFromListActionPerformed
		// TODO add your handling code here:
		if (!jListEmployees.isSelectionEmpty()) {
			int ind = jListEmployees.getSelectedIndex();
			reportIds.remove(ind);
			String temp = (String) jListEmployees.getSelectedValue();
			int index = listModel.indexOf(temp, 0);
			listModel.remove(index);
		} else
			JOptionPane.showMessageDialog(getComponent(0),
					"You must select an Employee from the list.");
	}// GEN-LAST:event_jButtonRemoveFromListActionPerformed

	private void jButtonViewHoursActionPerformed(java.awt.event.ActionEvent evt) {// GEN-FIRST:event_jButtonViewHoursActionPerformed
		// TODO add your handling code here:if
		
		if (!jListEmployees.isSelectionEmpty()) {

			DateTime startDate = new DateTime();
			DatePicker firstDate = new DatePicker();
			String start = "Select a start date";
			firstDate.buildDatePanel(start, startDate);
			startDate = firstDate.getSelectedDate();
			

			DateTime endDate = new DateTime();
			DatePicker secondDate = new DatePicker();
			String end = "Select an end date";
			secondDate.buildDatePanel(end, endDate);
			endDate = secondDate.getSelectedDate();
			if (endDate.compareTo(startDate) > 0) {
				try {
					int ind = jListEmployees.getSelectedIndex();
					int id = reportIds.get(ind);
//					System.out.println(id);
					// dump hours into a vector
					Vector<Log> hours = P.getHours(id, startDate, endDate);

					String name = P.getName(id);
					if (jTextArea1.getText().trim().length() > 0)
						jTextArea1.setText("");
					jTextArea1.append(name + "\n");

					// iterate through vector of returned hours
					Iterator itr = hours.iterator();
					while (itr.hasNext()) {
						Log log = (Log) itr.next();
						DateTime entered = log.dateEntered;
						DateTime shiftStart = log.startTime;
						DateTimeFormatter formatter = DateTimeFormat
								.forPattern("MMMM-dd-yyyy");
						String ent = entered.toString(formatter);
						String star = shiftStart.toString(formatter);

						jTextArea1.append("Date Entered: " + ent + "\n");
						jTextArea1.append("Start Date: " + star + "\n");
						jTextArea1.append("Hours Worked: " + log.hoursWorked
								+ "\n");
						jTextArea1.append("Entry #: " + log.entryNumber + "\n");
						jTextArea1.append("\n");
					}

				} catch (Exception e) {
					// TODO Auto-generated catch block
					e.printStackTrace();
				}
			} else
				JOptionPane.showMessageDialog(getComponent(0),
						"Your start date must be less than your end date");
		} else
			JOptionPane.showMessageDialog(getComponent(0),
					"You must select an Employee from the list.");

	}// GEN-LAST:event_jButtonViewHoursActionPerformed

	private void jButtonUpdateHoursActionPerformed(
			java.awt.event.ActionEvent evt) {// GEN-FIRST:event_jButtonUpdateHoursActionPerformed
		// TODO add your handling code here:
		String num = JOptionPane
				.showInputDialog("Please enter the entry number you would like to edit");
		if (isInteger(num)) {
			int entry = Integer.parseInt(num);
			String hrs = JOptionPane
					.showInputDialog("Please enter the correct number of hours");
			if (isDouble(hrs)) {
				double nhrs = Double.parseDouble(hrs);
				P.editEmployeeHours(entry, nhrs);
			} else
				JOptionPane
						.showMessageDialog(getComponent(0),
								"You must enter a numeric value for the number of hours worked");
		} else
			JOptionPane.showMessageDialog(getComponent(0),
					"You must enter a numeric value for the entry number.");
	}// GEN-LAST:event_jButtonUpdateHoursActionPerformed

	private void jButtonChangePayActionPerformed(java.awt.event.ActionEvent evt) {// GEN-FIRST:event_jButtonChangePayActionPerformed
		// TODO add your handling code here:
		if (!jListEmployees.isSelectionEmpty()) {
			int ind = jListEmployees.getSelectedIndex();
			int eid = reportIds.get(ind);

			String rate = JOptionPane
					.showInputDialog("Please enter the new pay rate for this employee");
			if (isDouble(rate)) {
				double nrate = Double.parseDouble(rate);
				try {
					Employee e = new Employee(eid);
					int id = e.getjobID();
					double max = P.getMaxPay(id);
					double min = P.getMinPay(id);

					if (nrate > max)
						JOptionPane.showMessageDialog(getComponent(0),
								"The new rate must not exceed " + max);
					if (nrate < min)
						JOptionPane.showMessageDialog(getComponent(0),
								"The new rate must not be less than " + min);
					else {
						P.changePayRate(eid, nrate);
					}

				} catch (Exception e) {
					// TODO Auto-generated catch block
					e.printStackTrace();
				}
			} else
				JOptionPane.showMessageDialog(getComponent(0),
						"You must enter a numeric value for the new pay rate");

		} else
			JOptionPane.showMessageDialog(getComponent(0),
					"You must select an Employee from the list.");
	}// GEN-LAST:event_jButtonChangePayActionPerformed

	private void jButtonTerminateEmployeeActionPerformed(
			java.awt.event.ActionEvent evt) {// GEN-FIRST:event_jButtonTerminateEmployeeActionPerformed
		// TODO add your handling code here:
		if (!jListEmployees.isSelectionEmpty()) {
			int ind = jListEmployees.getSelectedIndex();
			int id = reportIds.get(ind);
			P.removeEmployee(id);
			reportIds.remove(ind);
			String temp = (String) jListEmployees.getSelectedValue();
			int index = listModel.indexOf(temp, 0);
			listModel.remove(index);
		} else
			JOptionPane.showMessageDialog(getComponent(0),
					"You must select an Employee from the list to terminate.");
	}// GEN-LAST:event_jButtonTerminateEmployeeActionPerformed

	protected void jButtonCreateJobProfileActionPerformed(ActionEvent evt) {
		// TODO Auto-generated method stub

		if (m != null) {
			String name = JOptionPane
					.showInputDialog("Please enter the name of the profile to be created");
			String min = JOptionPane
					.showInputDialog("Please enter the Minimum Pay for the profile to be created");
			if (isDouble(min)) {
				double minPay = Double.parseDouble(min);

				String max = JOptionPane
						.showInputDialog("Please enter the Maximum Pay for the profile to be created");
				if (isDouble(max)) {
					double maxPay = Double.parseDouble(max);
					if (maxPay > minPay) {
						try {
							m.createNewPayGrade(name, minPay, maxPay);
						} catch (Exception e) {
							// TODO Auto-generated catch block
							e.printStackTrace();
						}
					} else
						JOptionPane.showMessageDialog(getComponent(0),
								"Minimum Pay must be less than Max Pay :(");
				}
			} else
				JOptionPane.showMessageDialog(getComponent(0),
						"The Job ID must be a numeric value :(");
		} else
			JOptionPane.showMessageDialog(getComponent(0),
					"Sorry you don't have manager access :(");
	}

	protected void jButtonChangeJobProfileActionPerformed(ActionEvent evt) {
		// TODO Auto-generated method stub

		if (!jListEmployees.isSelectionEmpty()) {
			int ind = jListEmployees.getSelectedIndex();
			int id = reportIds.get(ind);
			
			String jId = JOptionPane
					.showInputDialog("Please enter the id number of this employees new job profile");
			if(isInteger(jId))
			{
				int newId = Integer.parseInt(jId);
				P.changeJobID(id,newId);
			}
			else
				JOptionPane.showMessageDialog(getComponent(0),
						"You must enter a numberic value for job id");
//			

		}else
			JOptionPane.showMessageDialog(getComponent(0),
					"You must select an employee from the list :(");

	}

	private void jTextFieldEmployeeInputActionPerformed(
			java.awt.event.ActionEvent evt) {// GEN-FIRST:event_jTextFieldEmployeeInputActionPerformed
		// TODO add your handling code here:
	}// GEN-LAST:event_jTextFieldEmployeeInputActionPerformed

	private void jButtonGenerateReportActionPerformed(
			java.awt.event.ActionEvent evt) throws Exception {// GEN-FIRST:event_jButtonGenerateReportActionPerformed
		if (!reportIds.isEmpty()) {
			DateTime startDate = new DateTime();
			DatePicker firstDate = new DatePicker();
			String start = "Select a start date";
			firstDate.buildDatePanel(start, startDate);
			startDate = firstDate.getSelectedDate();
			firstDate.close();

			DateTime endDate = new DateTime();
			DatePicker secondDate = new DatePicker();
			String end = "Select an end date";
			secondDate.buildDatePanel(end, endDate);
			endDate = secondDate.getSelectedDate();
			if (endDate.compareTo(startDate) > 0) {
				Component C = null;
				P.generateReport(C, reportIds, startDate, endDate);
			} else
				JOptionPane.showMessageDialog(getComponent(0),
						"Your start date must be less than your end date");
		} else
			JOptionPane.showMessageDialog(getComponent(0),
					"You must add employees to the list to generate a report");

	}// GEN-LAST:event_jButtonGenerateReportActionPerformed

	public boolean isInteger(String input) {
		try {
			Integer.parseInt(input);
			return true;
		} catch (Exception e) {
			return false;
		}
	}

	public boolean isDouble(String input) {
		try {
			Double.parseDouble(input);
			return true;
		} catch (Exception e) {
			return false;
		}
	}

	/**
	 * @param args
	 *            the command line arguments
	 */
	public static void main(String args[]) {
		/* Set the Nimbus look and feel */
		// <editor-fold defaultstate="collapsed"
		// desc=" Look and feel setting code (optional) ">
		/*
		 * If Nimbus (introduced in Java SE 6) is not available, stay with the
		 * default look and feel. For details see
		 * http://download.oracle.com/javase
		 * /tutorial/uiswing/lookandfeel/plaf.html
		 */
		try {
			for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager
					.getInstalledLookAndFeels()) {
				if ("Nimbus".equals(info.getName())) {
					javax.swing.UIManager.setLookAndFeel(info.getClassName());
					break;
				}
			}
		} catch (ClassNotFoundException ex) {
			java.util.logging.Logger.getLogger(Payroll.class.getName()).log(
					java.util.logging.Level.SEVERE, null, ex);
		} catch (InstantiationException ex) {
			java.util.logging.Logger.getLogger(Payroll.class.getName()).log(
					java.util.logging.Level.SEVERE, null, ex);
		} catch (IllegalAccessException ex) {
			java.util.logging.Logger.getLogger(Payroll.class.getName()).log(
					java.util.logging.Level.SEVERE, null, ex);
		} catch (javax.swing.UnsupportedLookAndFeelException ex) {
			java.util.logging.Logger.getLogger(Payroll.class.getName()).log(
					java.util.logging.Level.SEVERE, null, ex);
		}
		// </editor-fold>

		/* Create and display the form */
		java.awt.EventQueue.invokeLater(new Runnable() {

			public void run() {
				PayrollAdmin P = null;
				Manager mp = null;
				try {

					mp = new Manager("th0r", "THORSMASH");
					P = new PayrollAdmin("th0r", "THORSMASH");

				} catch (Exception e) {
					e.printStackTrace();
				}
				new Payroll(mp).setVisible(true);
			}
		});
	}

	// Variables declaration - do not modify//GEN-BEGIN:variables
	private javax.swing.JButton jButtonAddToList;
	private javax.swing.JButton jButtonChangeJobProfile;
	private javax.swing.JButton jButtonChangePay;
	private javax.swing.JButton jButtonCreateJobProfile;
	private javax.swing.JButton jButtonGenerateReport;
	private javax.swing.JButton jButtonRemoveFromList;
	private javax.swing.JButton jButtonTerminateEmployee;
	private javax.swing.JButton jButtonUpdateHours;
	private javax.swing.JButton jButtonViewHours;
	private javax.swing.JComboBox jComboBoxEmployeeInput;
	private javax.swing.JList jListEmployees;
	private javax.swing.JScrollPane jScrollPane1;
	private javax.swing.JScrollPane jScrollPane2;
	private javax.swing.JTextArea jTextArea1;
	private PayrollAdmin P = null;
	private Manager m = null;

	private Employee em = null;
	private DefaultListModel<String> listModel = new DefaultListModel<String>();
	// End of variables declaration//GEN-END:variables
}
